QT       += core gui multimedia testlib

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

CONFIG += c++11

QMAKE_CC += -g
QMAKE_CXX += -g
QMAKE_LINK += -g

# The following define makes your compiler emit warnings if you use
# any Qt feature that has been marked deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS

# You can also make your code fail to compile if it uses deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
    DecodeAudio/decodeplayaudio.cpp \
    DecodeSave/decodeandsave.cpp \
    DecodeVideo/testplayvideo.cpp \
    FullyPlayer/audiodecoder.cpp \
    FullyPlayer/avpacketqueue.cpp \
    FullyPlayer/maindecoder.cpp \
    FullyPlayer/mainwindow.cpp \
    HwdDecodePlayVideo/hwddecodethread.cpp \
    HwdDecodePlayVideo/mainplaywidget.cpp \
    HwdDecodePlayVideo/playvideowidget.cpp \
    PrintInfo/basicinfo.cpp \
    SDLPlayVideo/sdlplayvideo.cpp \
    SoftDecodePlayVideo/decodevideothread.cpp \
    SoftDecodePlayVideo/i420render.cpp \
    SoftDecodePlayVideo/mainwidget.cpp \
    SoftDecodePlayVideo/playwidget.cpp \
    main.cpp

HEADERS += \
    DecodeAudio/decodeplayaudio.h \
    DecodeSave/decodeandsave.h \
    DecodeVideo/testplayvideo.h \
    FullyPlayer/audiodecoder.h \
    FullyPlayer/avpacketqueue.h \
    FullyPlayer/maindecoder.h \
    FullyPlayer/mainwindow.h \
    HwdDecodePlayVideo/hwddecodethread.h \
    HwdDecodePlayVideo/mainplaywidget.h \
    HwdDecodePlayVideo/playvideowidget.h \
    PrintInfo/basicinfo.h \
    SDLPlayVideo/sdlplayvideo.h \
    SoftDecodePlayVideo/decodevideothread.h \
    SoftDecodePlayVideo/i420render.h \
    SoftDecodePlayVideo/mainwidget.h \
    SoftDecodePlayVideo/playwidget.h

FORMS += \
    FullyPlayer/mainwindow.ui \
    HwdDecodePlayVideo/mainplaywidget.ui \
    HwdDecodePlayVideo/playvideowidget.ui \
    SoftDecodePlayVideo/mainwidget.ui \
    SoftDecodePlayVideo/playwidget.ui

# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target

INCLUDEPATH += /usr/local/ffmpeg/include
INCLUDEPATH += /usr/local/SDL2/include

LIBS += /usr/local/ffmpeg/lib/libavcodec.so      \
        /usr/local/ffmpeg/lib/libavdevice.so     \
        /usr/local/ffmpeg/lib/libavfilter.so     \
        /usr/local/ffmpeg/lib/libavformat.so     \
        /usr/local/ffmpeg/lib/libavutil.so       \
        /usr/local/ffmpeg/lib/libswresample.so   \
        /usr/local/ffmpeg/lib/libswscale.so      \
        /usr/local/ffmpeg/lib/libpostproc.so
LIBS += -L /usr/local/SDL2/lib -lSDL2

RESOURCES += \
    image.qrc

DISTFILES += \
    image/icon.rc
